// Learn TypeScript:
//  - https://docs.cocos.com/creator/manual/en/scripting/typescript.html
// Learn Attribute:
//  - https://docs.cocos.com/creator/manual/en/scripting/reference/attributes.html
// Learn life-cycle callbacks:
//  - https://docs.cocos.com/creator/manual/en/scripting/life-cycle-callbacks.html

const {ccclass, property} = cc._decorator;
import MainControl from "./mainControl"

@ccclass
export default class FlappyBird extends cc.Component {

    // 公共节点
    @property(MainControl)
    mainControl: MainControl = null;

    start () {

        this.mainControl = cc.find("persistentNode").getComponent("mainControl")
        // console.log(cc.director.getScene().getChildByName('persistentNode'))
        // console.log(cc.director.getScene().children)
    }

    // update (dt) {}
}
